//
//  Province.m
//  DIsciplineSelectPartner
//
//  Created by 唐秦崴 on 15/3/12.
//  Copyright (c) 2015年 唐秦崴. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "Province.h"

@implementation Province

- (instancetype)initWithPropertiesId : (NSString*) objectId
                                name : (NSString*) name
                           univesity : (BmobRelation*) university
                                image: (UIImage *) image
{
    self = [super init];
    
    self.objectId   = objectId;
    self.name       = name;
    self.university = university;
    self.image      = image;
    return self;
}

- (instancetype)initWithBmobObject : (BmobObject*) bmobObject
{
    self = [super init];
    
    if (bmobObject) {
        self.objectId   = bmobObject.objectId;
        self.name       = [bmobObject objectForKey:@"name"];
        self.university = [bmobObject objectForKey:@"university"];
    }
    
    return self;
    
}

@end